//
//  YSHomeCardVideoCell.m
//  Yueshi
//
//  Created by yueshi－mac1 on 15/12/16.
//  Copyright © 2015年 悦食中国. All rights reserved.
//

#import "YSHomeCardVideoCell.h"
#import "YSCardVideoItemView.h"
@interface YSHomeCardVideoCell()

@property (nonatomic,strong)YSCardVideoItemView *cardItemView;

@end

@implementation YSHomeCardVideoCell

+ (instancetype)cellWithTableView:(UITableView *)tableView
{
    static NSString *ID = @"YSHomeCardVideoCell";
    YSHomeCardVideoCell *cell = [tableView dequeueReusableCellWithIdentifier:ID];
    if (!cell) {
        cell = [[YSHomeCardVideoCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:ID];
    }
    return cell;
}

- (id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        YSCardVideoItemView *cardItemView =  [[YSCardVideoItemView alloc]init];
        self.cardItemView = cardItemView;
        [self addSubview:cardItemView];
    }
    return self;
}

- (void)setCardVideoFrame:(YSCardVideoItemFrame *)cardVideoFrame{
    _cardVideoFrame = cardVideoFrame;
    _cardItemView.cardVideoFrame = cardVideoFrame;
}

@end
